Standard Schema
A standard interface for TypeScript schema validation libraries
現在のcontributerは@colinhacks(zod)と@fabian-hiller(valibot)の二人
TypeScriptで実行時型検査系のライブラリのinterfaceの標準化の試み
trpcとかhonoとかreact-hook-formとかの開発者目線で、validationをサポートする際の手間が減る
github
Colin McDonnell (@colinhacks)
What if all the type validation libraries in the ecosystem implemented a shared interface?
Then other libraries that accept user-provided schemas (e.g. tRPC) could accept any "spec-compliant" validator and not need to implement special logic for each lib
Proposal:
https://gyazo.com/29a4262e31c9a714711efc4a0872247b
/miyamonz/Standard Schema